home *** CD-ROM | disk | FTP | other *** search
/ Mac Power 1997 January / macpower199701.bin / AMUG / Programming_10 / ICPAppSource+ICprogKit / ICAppSourceKit 1.3.sit / ICAppSourceKit1.3 / ICSoundPopupWhats.p < prev    next >
MacBinary  |  1996-07-20  |  4.4 KB  |  [TEXT/CWIE]

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text

This file was processed as: MacBinary (archive/macBinary).

You can browse this item here: ICSoundPopupWhats.p

ConfidenceProgramDetectionMatch TypeSupport
66% dexvert ZX81 Sinclair BASIC (image/sinclairBASIC) ext Supported
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Applause Picture (image/applausePicture) ext Unsupported
1% dexvert bsdiff patch (other/bsdiffPatch) ext Unsupported
1% dexvert imgdiff patch (other/imgdiffPatch) ext Unsupported
1% dexvert MATLAB p-code (other/matlabPCode) ext Unsupported
1% dexvert WSUS Patch Storage File (other/wsusPatchStorageFile) ext Unsupported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, inited, Sat Jul 20 15:03:04 1996, modified Sat Jul 20 15:03:04 1996, creator 'CWIE', type ASCII, 3758 bytes "ICSoundPopupWhats.p" , at 0xf2e 410 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[CWIE]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 13 49 43 53 6f 75 6e | 64 50 6f 70 75 70 57 68 |..ICSoun|dPopupWh|
|00000010| 61 74 73 2e 70 00 00 00 | 00 00 00 00 00 00 00 00 |ats.p...|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 43 57 49 | 45 01 00 00 00 00 00 00 |.TEXTCWI|E.......|
|00000050| 00 00 00 00 00 0e ae 00 | 00 01 9a ae 16 dd e8 ae |........|........|
|00000060| 16 dd e8 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 e4 8d 00 00 |........|........|
|00000080| 75 6e 69 74 20 49 43 53 | 6f 75 6e 64 50 6f 70 75 |unit ICS|oundPopu|
|00000090| 70 57 68 61 74 73 3b 0d | 0d 69 6e 74 65 72 66 61 |pWhats;.|.interfa|
|000000a0| 63 65 0d 0d 09 75 73 65 | 73 0d 09 09 49 43 57 69 |ce...use|s...ICWi|
|000000b0| 6e 64 6f 77 47 6c 6f 62 | 61 6c 73 3b 0d 0d 09 66 |ndowGlob|als;...f|
|000000c0| 75 6e 63 74 69 6f 6e 20 | 57 68 61 74 4f 70 65 6e |unction |WhatOpen|
|000000d0| 53 6f 75 6e 64 50 6f 70 | 75 70 20 28 77 74 3a 20 |SoundPop|up (wt: |
|000000e0| 57 69 6e 64 6f 77 54 79 | 70 65 3b 20 69 74 65 6d |WindowTy|pe; item|
|000000f0| 3a 20 69 6e 74 65 67 65 | 72 29 3a 20 4f 53 45 72 |: intege|r): OSEr|
|00000100| 72 3b 0d 09 66 75 6e 63 | 74 69 6f 6e 20 57 68 61 |r;..func|tion Wha|
|00000110| 74 46 6c 75 73 68 53 6f | 75 6e 64 50 6f 70 75 70 |tFlushSo|undPopup|
|00000120| 20 28 77 74 3a 20 57 69 | 6e 64 6f 77 54 79 70 65 | (wt: Wi|ndowType|
|00000130| 3b 20 69 74 65 6d 3a 20 | 69 6e 74 65 67 65 72 29 |; item: |integer)|
|00000140| 3a 20 4f 53 45 72 72 3b | 0d 09 66 75 6e 63 74 69 |: OSErr;|..functi|
|00000150| 6f 6e 20 57 68 61 74 43 | 6c 69 63 6b 53 6f 75 6e |on WhatC|lickSoun|
|00000160| 64 50 6f 70 75 70 20 28 | 77 74 3a 20 57 69 6e 64 |dPopup (|wt: Wind|
|00000170| 6f 77 54 79 70 65 3b 20 | 69 74 65 6d 3a 20 69 6e |owType; |item: in|
|00000180| 74 65 67 65 72 3b 20 65 | 72 3a 20 65 76 65 6e 74 |teger; e|r: event|
|00000190| 52 65 63 6f 72 64 29 3a | 20 4f 53 45 72 72 3b 0d |Record):| OSErr;.|
|000001a0| 0d 69 6d 70 6c 65 6d 65 | 6e 74 61 74 69 6f 6e 0d |.impleme|ntation.|
|000001b0| 0d 09 75 73 65 73 0d 09 | 09 54 65 78 74 55 74 69 |..uses..|.TextUti|
|000001c0| 6c 73 2c 0d 09 09 53 6f | 75 6e 64 2c 0d 09 09 52 |ls,...So|und,...R|
|000001d0| 65 73 6f 75 72 63 65 73 | 2c 0d 09 09 0d 09 09 49 |esources|,......I|
|000001e0| 43 41 50 49 2c 0d 09 09 | 49 43 53 75 62 73 2c 0d |CAPI,...|ICSubs,.|
|000001f0| 09 09 49 43 44 69 61 6c | 6f 67 73 2c 0d 09 09 49 |..ICDial|ogs,...I|
|00000200| 43 44 6f 63 75 6d 65 6e | 74 2c 0d 09 09 49 43 4d |CDocumen|t,...ICM|
|00000210| 69 73 63 53 75 62 73 2c | 0d 09 09 49 43 47 6c 6f |iscSubs,|...ICGlo|
|00000220| 62 61 6c 73 3b 0d 0d 09 | 66 75 6e 63 74 69 6f 6e |bals;...|function|
|00000230| 20 57 68 61 74 4f 70 65 | 6e 53 6f 75 6e 64 50 6f | WhatOpe|nSoundPo|
|00000240| 70 75 70 20 28 77 74 3a | 20 57 69 6e 64 6f 77 54 |pup (wt:| WindowT|
|00000250| 79 70 65 3b 20 69 74 65 | 6d 3a 20 69 6e 74 65 67 |ype; ite|m: integ|
|00000260| 65 72 29 3a 20 4f 53 45 | 72 72 3b 0d 09 09 76 61 |er): OSE|rr;...va|
|00000270| 72 0d 09 09 09 6d 65 6e | 75 68 20 3a 20 4d 65 6e |r....men|uh : Men|
|00000280| 75 48 61 6e 64 6c 65 3b | 0d 09 09 09 6d 65 6e 75 |uHandle;|....menu|
|00000290| 5f 69 6e 64 65 78 20 3a | 20 69 6e 74 65 67 65 72 |_index :| integer|
|000002a0| 3b 0d 09 09 09 70 72 65 | 66 65 72 65 6e 63 65 5f |;....pre|ference_|
|000002b0| 66 6f 75 6e 64 5f 69 6e | 5f 6d 65 6e 75 20 3a 20 |found_in|_menu : |
|000002c0| 42 6f 6f 6c 65 61 6e 3b | 0d 09 09 09 63 75 72 72 |Boolean;|....curr|
|000002d0| 65 6e 74 5f 73 6f 75 6e | 64 5f 6e 61 6d 65 20 3a |ent_soun|d_name :|
|000002e0| 20 53 74 72 32 35 35 3b | 0d 09 09 09 61 74 74 72 | Str255;|....attr|
|000002f0| 20 3a 20 49 43 41 74 74 | 72 3b 0d 09 09 09 6d 65 | : ICAtt|r;....me|
|00000300| 6e 75 5f 63 6f 75 6e 74 | 20 3a 20 69 6e 74 65 67 |nu_count| : integ|
|00000310| 65 72 3b 0d 09 09 09 69 | 74 65 6d 5f 74 65 78 74 |er;....i|tem_text|
|00000320| 20 3a 20 53 74 72 32 35 | 35 3b 0d 09 62 65 67 69 | : Str25|5;..begi|
|00000330| 6e 0d 09 09 6d 65 6e 75 | 68 20 3a 3d 20 47 65 74 |n...menu|h := Get|
|00000340| 50 6f 70 75 70 4d 48 61 | 6e 64 6c 65 28 77 69 6e |PopupMHa|ndle(win|
|00000350| 64 6f 77 69 6e 66 6f 5b | 77 74 5d 2e 77 69 6e 64 |dowinfo[|wt].wind|
|00000360| 6f 77 2c 20 69 74 65 6d | 29 3b 0d 09 09 0d 09 09 |ow, item|);......|
|00000370| 28 2a 20 47 65 74 20 74 | 68 65 20 63 75 72 72 65 |(* Get t|he curre|
|00000380| 6e 74 20 76 61 6c 75 65 | 2e 20 20 49 66 20 77 65 |nt value|. If we|
|00000390| 20 63 61 6e 27 74 20 67 | 65 74 20 69 74 2c 20 75 | can't g|et it, u|
|000003a0| 73 65 20 74 68 65 20 66 | 69 72 73 74 20 69 74 65 |se the f|irst ite|
|000003b0| 6d 20 66 72 6f 6d 20 74 | 68 65 20 6d 65 6e 75 20 |m from t|he menu |
|000003c0| 61 73 20 61 20 64 65 66 | 61 75 6c 74 2e 20 2a 29 |as a def|ault. *)|
|000003d0| 0d 09 09 69 66 20 49 43 | 47 65 74 50 72 65 66 53 |...if IC|GetPrefS|
|000003e0| 74 72 20 28 47 65 74 49 | 6e 73 74 61 6e 63 65 2c |tr (GetI|nstance,|
|000003f0| 20 77 69 6e 64 6f 77 69 | 6e 66 6f 5b 77 74 5d 2e | windowi|nfo[wt].|
|00000400| 69 74 65 6d 73 5b 69 74 | 65 6d 5d 5e 2e 6b 65 79 |items[it|em]^.key|
|00000410| 2c 20 61 74 74 72 2c 20 | 63 75 72 72 65 6e 74 5f |, attr, |current_|
|00000420| 73 6f 75 6e 64 5f 6e 61 | 6d 65 29 20 3c 3e 20 6e |sound_na|me) <> n|
|00000430| 6f 45 72 72 20 74 68 65 | 6e 20 62 65 67 69 6e 0d |oErr the|n begin.|
|00000440| 09 09 09 47 65 74 4d 65 | 6e 75 49 74 65 6d 54 65 |...GetMe|nuItemTe|
|00000450| 78 74 28 6d 65 6e 75 68 | 2c 20 31 2c 20 63 75 72 |xt(menuh|, 1, cur|
|00000460| 72 65 6e 74 5f 73 6f 75 | 6e 64 5f 6e 61 6d 65 29 |rent_sou|nd_name)|
|00000470| 3b 0d 09 09 65 6e 64 3b | 20 28 2a 20 69 66 20 2a |;...end;| (* if *|
|00000480| 29 0d 09 09 50 72 6f 63 | 65 73 73 41 74 74 72 69 |)...Proc|essAttri|
|00000490| 62 75 74 65 73 28 77 74 | 2c 20 69 74 65 6d 2c 20 |butes(wt|, item, |
|000004a0| 61 74 74 72 29 3b 0d 0d | 09 09 28 2a 20 46 69 6e |attr);..|..(* Fin|
|000004b0| 64 20 74 68 65 20 63 75 | 72 72 65 6e 74 20 76 61 |d the cu|rrent va|
|000004c0| 6c 75 65 20 69 6e 20 74 | 68 65 20 6d 65 6e 75 2e |lue in t|he menu.|
|000004d0| 20 2a 29 0d 09 09 70 72 | 65 66 65 72 65 6e 63 65 | *)...pr|eference|
|000004e0| 5f 66 6f 75 6e 64 5f 69 | 6e 5f 6d 65 6e 75 20 3a |_found_i|n_menu :|
|000004f0| 3d 20 66 61 6c 73 65 3b | 0d 09 09 6d 65 6e 75 5f |= false;|...menu_|
|00000500| 63 6f 75 6e 74 20 3a 3d | 20 20 43 6f 75 6e 74 4d |count :=| CountM|
|00000510| 49 74 65 6d 73 28 6d 65 | 6e 75 68 29 3b 0d 09 09 |Items(me|nuh);...|
|00000520| 6d 65 6e 75 5f 69 6e 64 | 65 78 20 3a 3d 20 31 3b |menu_ind|ex := 1;|
|00000530| 0d 09 09 77 68 69 6c 65 | 20 6e 6f 74 20 70 72 65 |...while| not pre|
|00000540| 66 65 72 65 6e 63 65 5f | 66 6f 75 6e 64 5f 69 6e |ference_|found_in|
|00000550| 5f 6d 65 6e 75 20 61 6e | 64 20 28 6d 65 6e 75 5f |_menu an|d (menu_|
|00000560| 69 6e 64 65 78 20 3c 3d | 20 6d 65 6e 75 5f 63 6f |index <=| menu_co|
|00000570| 75 6e 74 29 20 64 6f 20 | 62 65 67 69 6e 0d 09 09 |unt) do |begin...|
|00000580| 09 47 65 74 4d 65 6e 75 | 49 74 65 6d 54 65 78 74 |.GetMenu|ItemText|
|00000590| 28 6d 65 6e 75 68 2c 20 | 6d 65 6e 75 5f 69 6e 64 |(menuh, |menu_ind|
|000005a0| 65 78 2c 20 69 74 65 6d | 5f 74 65 78 74 29 3b 0d |ex, item|_text);.|
|000005b0| 09 09 09 69 66 20 49 55 | 43 6f 6d 70 53 74 72 69 |...if IU|CompStri|
|000005c0| 6e 67 28 69 74 65 6d 5f | 74 65 78 74 2c 20 63 75 |ng(item_|text, cu|
|000005d0| 72 72 65 6e 74 5f 73 6f | 75 6e 64 5f 6e 61 6d 65 |rrent_so|und_name|
|000005e0| 29 20 3d 20 30 20 74 68 | 65 6e 20 62 65 67 69 6e |) = 0 th|en begin|
|000005f0| 0d 09 09 09 09 70 72 65 | 66 65 72 65 6e 63 65 5f |.....pre|ference_|
|00000600| 66 6f 75 6e 64 5f 69 6e | 5f 6d 65 6e 75 20 3a 3d |found_in|_menu :=|
|00000610| 20 74 72 75 65 3b 0d 09 | 09 09 65 6e 64 20 65 6c | true;..|..end el|
|00000620| 73 65 20 62 65 67 69 6e | 0d 09 09 09 09 6d 65 6e |se begin|.....men|
|00000630| 75 5f 69 6e 64 65 78 20 | 3a 3d 20 6d 65 6e 75 5f |u_index |:= menu_|
|00000640| 69 6e 64 65 78 20 2b 20 | 31 3b 0d 09 09 09 65 6e |index + |1;....en|
|00000650| 64 3b 20 28 2a 20 69 66 | 20 2a 29 0d 09 09 65 6e |d; (* if| *)...en|
|00000660| 64 3b 20 28 2a 20 66 6f | 72 20 2a 29 0d 09 09 0d |d; (* fo|r *)....|
|00000670| 09 09 28 2a 20 49 66 20 | 69 74 27 73 20 6e 6f 74 |..(* If |it's not|
|00000680| 20 74 68 65 72 65 2c 20 | 61 64 64 20 69 74 20 61 | there, |add it a|
|00000690| 74 20 74 68 65 20 65 6e | 64 2e 20 2a 29 0d 09 09 |t the en|d. *)...|
|000006a0| 69 66 20 6e 6f 74 20 70 | 72 65 66 65 72 65 6e 63 |if not p|referenc|
|000006b0| 65 5f 66 6f 75 6e 64 5f | 69 6e 5f 6d 65 6e 75 20 |e_found_|in_menu |
|000006c0| 74 68 65 6e 20 62 65 67 | 69 6e 0d 09 09 09 41 70 |then beg|in....Ap|
|000006d0| 70 65 6e 64 4d 65 6e 75 | 28 6d 65 6e 75 68 2c 20 |pendMenu|(menuh, |
|000006e0| 27 28 2d 27 29 3b 0d 09 | 09 09 53 61 66 65 41 70 |'(-');..|..SafeAp|
|000006f0| 70 65 6e 64 4d 65 6e 75 | 28 6d 65 6e 75 68 2c 20 |pendMenu|(menuh, |
|00000700| 63 75 72 72 65 6e 74 5f | 73 6f 75 6e 64 5f 6e 61 |current_|sound_na|
|00000710| 6d 65 29 3b 0d 09 09 09 | 6d 65 6e 75 5f 69 6e 64 |me);....|menu_ind|
|00000720| 65 78 20 3a 3d 20 43 6f | 75 6e 74 4d 49 74 65 6d |ex := Co|untMItem|
|00000730| 73 28 6d 65 6e 75 68 29 | 3b 0d 09 09 09 53 65 74 |s(menuh)|;....Set|
|00000740| 43 6f 6e 74 72 6f 6c 4d | 61 78 69 6d 75 6d 28 47 |ControlM|aximum(G|
|00000750| 65 74 44 43 6f 6e 74 72 | 6f 6c 48 61 6e 64 6c 65 |etDContr|olHandle|
|00000760| 28 77 69 6e 64 6f 77 69 | 6e 66 6f 5b 77 74 5d 2e |(windowi|nfo[wt].|
|00000770| 77 69 6e 64 6f 77 2c 20 | 69 74 65 6d 29 2c 20 6d |window, |item), m|
|00000780| 65 6e 75 5f 69 6e 64 65 | 78 29 3b 0d 09 09 65 6e |enu_inde|x);...en|
|00000790| 64 3b 20 28 2a 20 69 66 | 20 2a 29 0d 0d 09 09 28 |d; (* if| *)....(|
|000007a0| 2a 20 50 72 65 70 61 72 | 65 20 74 68 65 20 63 6f |* Prepar|e the co|
|000007b0| 6e 74 72 6f 6c 2e 20 2a | 29 0d 09 09 53 65 74 44 |ntrol. *|)...SetD|
|000007c0| 43 74 6c 56 61 6c 75 65 | 28 77 69 6e 64 6f 77 69 |CtlValue|(windowi|
|000007d0| 6e 66 6f 5b 77 74 5d 2e | 77 69 6e 64 6f 77 2c 20 |nfo[wt].|window, |
|000007e0| 69 74 65 6d 2c 20 6d 65 | 6e 75 5f 69 6e 64 65 78 |item, me|nu_index|
|000007f0| 29 3b 0d 09 09 53 65 74 | 44 43 74 6c 45 6e 61 62 |);...Set|DCtlEnab|
|00000800| 6c 65 28 77 69 6e 64 6f | 77 69 6e 66 6f 5b 77 74 |le(windo|winfo[wt|
|00000810| 5d 2e 77 69 6e 64 6f 77 | 2c 20 69 74 65 6d 2c 20 |].window|, item, |
|00000820| 6e 6f 74 20 49 73 4c 6f | 63 6b 65 64 28 77 74 2c |not IsLo|cked(wt,|
|00000830| 20 69 74 65 6d 29 29 3b | 0d 09 09 0d 09 09 77 69 | item));|......wi|
|00000840| 6e 64 6f 77 69 6e 66 6f | 5b 77 74 5d 2e 69 74 65 |ndowinfo|[wt].ite|
|00000850| 6d 73 5b 69 74 65 6d 5d | 5e 2e 6d 6f 64 69 66 69 |ms[item]|^.modifi|
|00000860| 65 64 20 3a 3d 20 66 61 | 6c 73 65 3b 0d 09 09 0d |ed := fa|lse;....|
|00000870| 09 09 57 68 61 74 4f 70 | 65 6e 53 6f 75 6e 64 50 |..WhatOp|enSoundP|
|00000880| 6f 70 75 70 20 3a 3d 20 | 6e 6f 45 72 72 3b 0d 09 |opup := |noErr;..|
|00000890| 65 6e 64 3b 20 28 2a 20 | 57 68 61 74 4f 70 65 6e |end; (* |WhatOpen|
|000008a0| 53 6f 75 6e 64 50 6f 70 | 75 70 20 2a 29 0d 09 0d |SoundPop|up *)...|
|000008b0| 09 66 75 6e 63 74 69 6f | 6e 20 47 65 74 4e 61 6d |.functio|n GetNam|
|000008c0| 65 4f 66 43 75 72 72 65 | 6e 74 53 6f 75 6e 64 28 |eOfCurre|ntSound(|
|000008d0| 77 74 3a 20 57 69 6e 64 | 6f 77 54 79 70 65 3b 20 |wt: Wind|owType; |
|000008e0| 69 74 65 6d 3a 20 69 6e | 74 65 67 65 72 29 20 3a |item: in|teger) :|
|000008f0| 20 53 74 72 32 35 35 3b | 0d 09 09 76 61 72 0d 09 | Str255;|...var..|
|00000900| 09 09 64 6c 67 20 3a 20 | 44 69 61 6c 6f 67 50 74 |..dlg : |DialogPt|
|00000910| 72 3b 0d 09 09 09 63 75 | 72 72 65 6e 74 5f 63 6f |r;....cu|rrent_co|
|00000920| 6e 74 72 6f 6c 5f 76 61 | 6c 75 65 20 3a 20 69 6e |ntrol_va|lue : in|
|00000930| 74 65 67 65 72 3b 0d 09 | 09 09 63 75 72 72 65 6e |teger;..|..curren|
|00000940| 74 5f 73 6f 75 6e 64 5f | 6e 61 6d 65 20 3a 20 53 |t_sound_|name : S|
|00000950| 74 72 32 35 35 3b 0d 09 | 62 65 67 69 6e 0d 09 09 |tr255;..|begin...|
|00000960| 64 6c 67 20 3a 3d 20 77 | 69 6e 64 6f 77 69 6e 66 |dlg := w|indowinf|
|00000970| 6f 5b 77 74 5d 2e 77 69 | 6e 64 6f 77 3b 0d 09 09 |o[wt].wi|ndow;...|
|00000980| 63 75 72 72 65 6e 74 5f | 63 6f 6e 74 72 6f 6c 5f |current_|control_|
|00000990| 76 61 6c 75 65 20 3a 3d | 20 47 65 74 44 43 74 6c |value :=| GetDCtl|
|000009a0| 56 61 6c 75 65 28 64 6c | 67 2c 20 69 74 65 6d 29 |Value(dl|g, item)|
|000009b0| 3b 0d 09 09 47 65 74 4d | 65 6e 75 49 74 65 6d 54 |;...GetM|enuItemT|
|000009c0| 65 78 74 28 47 65 74 50 | 6f 70 75 70 4d 48 61 6e |ext(GetP|opupMHan|
|000009d0| 64 6c 65 28 64 6c 67 2c | 20 69 74 65 6d 29 2c 20 |dle(dlg,| item), |
|000009e0| 63 75 72 72 65 6e 74 5f | 63 6f 6e 74 72 6f 6c 5f |current_|control_|
|000009f0| 76 61 6c 75 65 2c 20 63 | 75 72 72 65 6e 74 5f 73 |value, c|urrent_s|
|00000a00| 6f 75 6e 64 5f 6e 61 6d | 65 29 3b 0d 09 09 47 65 |ound_nam|e);...Ge|
|00000a10| 74 4e 61 6d 65 4f 66 43 | 75 72 72 65 6e 74 53 6f |tNameOfC|urrentSo|
|00000a20| 75 6e 64 20 3a 3d 20 63 | 75 72 72 65 6e 74 5f 73 |und := c|urrent_s|
|00000a30| 6f 75 6e 64 5f 6e 61 6d | 65 3b 0d 09 65 6e 64 3b |ound_nam|e;..end;|
|00000a40| 20 28 2a 20 47 65 74 4e | 61 6d 65 4f 66 43 75 72 | (* GetN|ameOfCur|
|00000a50| 72 65 6e 74 53 6f 75 6e | 64 20 2a 29 0d 09 0d 09 |rentSoun|d *)....|
|00000a60| 66 75 6e 63 74 69 6f 6e | 20 57 68 61 74 46 6c 75 |function| WhatFlu|
|00000a70| 73 68 53 6f 75 6e 64 50 | 6f 70 75 70 20 28 77 74 |shSoundP|opup (wt|
|00000a80| 3a 20 57 69 6e 64 6f 77 | 54 79 70 65 3b 20 69 74 |: Window|Type; it|
|00000a90| 65 6d 3a 20 69 6e 74 65 | 67 65 72 29 3a 20 4f 53 |em: inte|ger): OS|
|00000aa0| 45 72 72 3b 0d 09 09 76 | 61 72 0d 09 09 09 65 72 |Err;...v|ar....er|
|00000ab0| 72 20 3a 20 4f 53 45 72 | 72 3b 0d 09 09 09 63 75 |r : OSEr|r;....cu|
|00000ac0| 72 72 65 6e 74 5f 73 6f | 75 6e 64 5f 6e 61 6d 65 |rrent_so|und_name|
|00000ad0| 20 3a 20 53 74 72 32 35 | 35 3b 0d 09 62 65 67 69 | : Str25|5;..begi|
|00000ae0| 6e 0d 09 09 65 72 72 20 | 3a 3d 20 6e 6f 45 72 72 |n...err |:= noErr|
|00000af0| 3b 0d 09 09 63 75 72 72 | 65 6e 74 5f 73 6f 75 6e |;...curr|ent_soun|
|00000b00| 64 5f 6e 61 6d 65 20 3a | 3d 20 47 65 74 4e 61 6d |d_name :|= GetNam|
|00000b10| 65 4f 66 43 75 72 72 65 | 6e 74 53 6f 75 6e 64 28 |eOfCurre|ntSound(|
|00000b20| 77 74 2c 20 69 74 65 6d | 29 3b 0d 09 09 69 66 20 |wt, item|);...if |
|00000b30| 77 69 6e 64 6f 77 69 6e | 66 6f 5b 77 74 5d 2e 69 |windowin|fo[wt].i|
|00000b40| 74 65 6d 73 5b 69 74 65 | 6d 5d 5e 2e 6d 6f 64 69 |tems[ite|m]^.modi|
|00000b50| 66 69 65 64 20 74 68 65 | 6e 20 62 65 67 69 6e 0d |fied the|n begin.|
|00000b60| 09 09 09 65 72 72 20 3a | 3d 20 49 43 4d 61 70 45 |...err :|= ICMapE|
|00000b70| 72 72 28 49 43 53 65 74 | 50 72 65 66 53 74 72 28 |rr(ICSet|PrefStr(|
|00000b80| 47 65 74 49 6e 73 74 61 | 6e 63 65 2c 20 77 69 6e |GetInsta|nce, win|
|00000b90| 64 6f 77 69 6e 66 6f 5b | 77 74 5d 2e 69 74 65 6d |dowinfo[|wt].item|
|00000ba0| 73 5b 69 74 65 6d 5d 5e | 2e 6b 65 79 2c 20 49 43 |s[item]^|.key, IC|
|00000bb0| 61 74 74 72 5f 6e 6f 5f | 63 68 61 6e 67 65 2c 20 |attr_no_|change, |
|00000bc0| 63 75 72 72 65 6e 74 5f | 73 6f 75 6e 64 5f 6e 61 |current_|sound_na|
|00000bd0| 6d 65 29 29 3b 0d 09 09 | 09 77 69 6e 64 6f 77 69 |me));...|.windowi|
|00000be0| 6e 66 6f 5b 77 74 5d 2e | 69 74 65 6d 73 5b 69 74 |nfo[wt].|items[it|
|00000bf0| 65 6d 5d 5e 2e 6d 6f 64 | 69 66 69 65 64 20 3a 3d |em]^.mod|ified :=|
|00000c00| 20 66 61 6c 73 65 3b 0d | 09 09 65 6e 64 3b 20 28 | false;.|..end; (|
|00000c10| 2a 20 69 66 20 2a 29 0d | 09 09 57 68 61 74 46 6c |* if *).|..WhatFl|
|00000c20| 75 73 68 53 6f 75 6e 64 | 50 6f 70 75 70 20 3a 3d |ushSound|Popup :=|
|00000c30| 20 65 72 72 3b 0d 09 65 | 6e 64 3b 20 28 2a 20 57 | err;..e|nd; (* W|
|00000c40| 68 61 74 46 6c 75 73 68 | 53 6f 75 6e 64 50 6f 70 |hatFlush|SoundPop|
|00000c50| 75 70 20 2a 29 0d 09 0d | 09 66 75 6e 63 74 69 6f |up *)...|.functio|
|00000c60| 6e 20 57 68 61 74 43 6c | 69 63 6b 53 6f 75 6e 64 |n WhatCl|ickSound|
|00000c70| 50 6f 70 75 70 20 28 77 | 74 3a 20 57 69 6e 64 6f |Popup (w|t: Windo|
|00000c80| 77 54 79 70 65 3b 20 69 | 74 65 6d 3a 20 69 6e 74 |wType; i|tem: int|
|00000c90| 65 67 65 72 3b 20 65 72 | 3a 20 65 76 65 6e 74 52 |eger; er|: eventR|
|00000ca0| 65 63 6f 72 64 29 3a 20 | 4f 53 45 72 72 3b 0d 09 |ecord): |OSErr;..|
|00000cb0| 09 76 61 72 0d 09 09 09 | 65 72 72 20 3a 20 4f 53 |.var....|err : OS|
|00000cc0| 45 72 72 3b 0d 09 09 09 | 63 75 72 72 65 6e 74 5f |Err;....|current_|
|00000cd0| 73 6f 75 6e 64 20 3a 20 | 53 6e 64 4c 69 73 74 48 |sound : |SndListH|
|00000ce0| 61 6e 64 6c 65 3b 0d 09 | 09 09 6a 75 6e 6b 5f 6c |andle;..|..junk_l|
|00000cf0| 6f 6e 67 20 3a 20 6c 6f | 6e 67 69 6e 74 3b 0d 09 |ong : lo|ngint;..|
|00000d00| 09 09 6a 75 6e 6b 20 3a | 20 4f 53 45 72 72 3b 0d |..junk :| OSErr;.|
|00000d10| 09 62 65 67 69 6e 0d 09 | 09 7b 24 75 6e 75 73 65 |.begin..|.{$unuse|
|00000d20| 64 20 65 72 7d 0d 09 09 | 65 72 72 20 3a 3d 20 6e |d er}...|err := n|
|00000d30| 6f 45 72 72 3b 0d 09 09 | 69 66 20 6e 6f 74 20 49 |oErr;...|if not I|
|00000d40| 73 4b 65 79 44 6f 77 6e | 20 28 6b 4f 70 74 69 6f |sKeyDown| (kOptio|
|00000d50| 6e 4b 65 79 43 6f 64 65 | 29 20 74 68 65 6e 20 62 |nKeyCode|) then b|
|00000d60| 65 67 69 6e 0d 09 09 09 | 63 75 72 72 65 6e 74 5f |egin....|current_|
|00000d70| 73 6f 75 6e 64 20 3a 3d | 20 53 6e 64 4c 69 73 74 |sound :=| SndList|
|00000d80| 48 61 6e 64 6c 65 28 47 | 65 74 4e 61 6d 65 64 52 |Handle(G|etNamedR|
|00000d90| 65 73 6f 75 72 63 65 28 | 27 73 6e 64 20 27 2c 20 |esource(|'snd ', |
|00000da0| 47 65 74 4e 61 6d 65 4f | 66 43 75 72 72 65 6e 74 |GetNameO|fCurrent|
|00000db0| 53 6f 75 6e 64 28 77 74 | 2c 20 69 74 65 6d 29 29 |Sound(wt|, item))|
|00000dc0| 29 3b 0d 09 09 09 69 66 | 20 63 75 72 72 65 6e 74 |);....if| current|
|00000dd0| 5f 73 6f 75 6e 64 20 3c | 3e 20 6e 69 6c 20 74 68 |_sound <|> nil th|
|00000de0| 65 6e 20 62 65 67 69 6e | 0d 09 09 09 09 6a 75 6e |en begin|.....jun|
|00000df0| 6b 20 3a 3d 20 53 6e 64 | 50 6c 61 79 28 6e 69 6c |k := Snd|Play(nil|
|00000e00| 2c 20 63 75 72 72 65 6e | 74 5f 73 6f 75 6e 64 2c |, curren|t_sound,|
|00000e10| 20 66 61 6c 73 65 29 3b | 0d 09 09 09 65 6e 64 20 | false);|....end |
|00000e20| 65 6c 73 65 20 62 65 67 | 69 6e 0d 09 09 09 09 46 |else beg|in.....F|
|00000e30| 6c 61 73 68 4d 65 6e 75 | 42 61 72 28 30 29 3b 0d |lashMenu|Bar(0);.|
|00000e40| 09 09 09 09 44 65 6c 61 | 79 28 36 2c 20 6a 75 6e |....Dela|y(6, jun|
|00000e50| 6b 5f 6c 6f 6e 67 29 3b | 0d 09 09 09 09 46 6c 61 |k_long);|.....Fla|
|00000e60| 73 68 4d 65 6e 75 42 61 | 72 28 30 29 3b 0d 09 09 |shMenuBa|r(0);...|
|00000e70| 09 65 6e 64 3b 20 28 2a | 20 69 66 20 2a 29 0d 09 |.end; (*| if *)..|
|00000e80| 09 65 6e 64 3b 20 28 2a | 20 69 66 20 2a 29 0d 0d |.end; (*| if *)..|
|00000e90| 09 09 77 69 6e 64 6f 77 | 69 6e 66 6f 5b 77 74 5d |..window|info[wt]|
|00000ea0| 2e 69 74 65 6d 73 5b 69 | 74 65 6d 5d 5e 2e 6d 6f |.items[i|tem]^.mo|
|00000eb0| 64 69 66 69 65 64 20 3a | 3d 20 74 72 75 65 3b 0d |dified :|= true;.|
|00000ec0| 09 09 44 69 72 74 79 44 | 6f 63 75 6d 65 6e 74 3b |..DirtyD|ocument;|
|00000ed0| 0d 0d 09 09 57 68 61 74 | 43 6c 69 63 6b 53 6f 75 |....What|ClickSou|
|00000ee0| 6e 64 50 6f 70 75 70 20 | 3a 3d 20 65 72 72 3b 0d |ndPopup |:= err;.|
|00000ef0| 09 65 6e 64 3b 20 28 2a | 20 57 68 61 74 43 6c 69 |.end; (*| WhatCli|
|00000f00| 63 6b 53 6f 75 6e 64 50 | 6f 70 75 70 20 2a 29 0d |ckSoundP|opup *).|
|00000f10| 09 0d 65 6e 64 2e 20 28 | 2a 20 49 43 53 6f 75 6e |..end. (|* ICSoun|
|00000f20| 64 50 6f 70 75 70 57 68 | 61 74 73 20 2a 29 00 00 |dPopupWh|ats *)..|
|00000f30| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000f40| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000f50| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000f60| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000f70| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000f80| 00 00 01 00 00 00 01 54 | 00 00 00 54 00 00 00 46 |.......T|...T...F|
|00000f90| 20 61 6c 0d 2b 20 72 65 | 6d 6f 6e 65 20 74 72 61 | al.+ re|mone tra|
|00000fa0| 69 6c 69 6e 67 20 64 6f | 74 20 66 72 6f 6d 20 55 |iling do|t from U|
|00000fb0| 13 49 43 53 6f 75 6e 64 | 50 6f 70 75 70 57 68 61 |.ICSound|PopupWha|
|00000fc0| 74 73 2e 70 02 00 00 00 | 54 45 58 54 43 57 49 45 |ts.p....|TEXTCWIE|
|00000fd0| 00 00 54 45 58 54 43 57 | 49 45 00 00 ff ff ff ff |..TEXTCW|IE......|
|00000fe0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000ff0| 00 00 ae 0e e4 28 00 00 | 0e ae 00 00 01 9a 20 65 |.....(..|...... e|
|00001000| 73 70 65 63 69 61 6c 6c | 79 20 61 64 64 20 74 68 |speciall|y add th|
|00001010| 65 20 41 70 70 6c 65 20 | 55 4d 69 63 68 20 6d 69 |e Apple |UMich mi|
|00001020| 72 72 6f 72 21 0d a5 20 | 6a 61 76 61 20 66 69 6c |rror!.. |java fil|
|00001030| 65 20 74 79 70 65 73 20 | d1 20 73 65 65 20 50 4e |e types |. see PN|
|00001040| 4c 0d a5 20 2e 65 78 65 | 20 68 61 64 20 6e 6f 20 |L.. .exe| had no |
|00001050| 61 73 73 6f 74 69 61 74 | 65 64 20 6d 69 6d 65 20 |assotiat|ed mime |
|00001060| 74 79 70 65 2e 20 54 68 | 65 20 74 79 70 65 20 73 |type. Th|e type s|
|00001070| 68 6f 75 6c 64 20 62 65 | 20 61 70 70 6c 69 63 61 |hould be| applica|
|00001080| 00 00 00 48 00 09 47 65 | 6e 65 76 61 00 00 00 00 |...H..Ge|neva....|
|00001090| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000010a0| 00 00 00 00 00 00 00 03 | 00 02 00 40 00 04 01 cd |........|...@....|
|000010b0| 02 63 00 40 00 04 01 cd | 02 63 ae 16 a5 ac 00 00 |.c.@....|.c......|
|000010c0| 07 73 00 00 07 b9 00 00 | 05 a9 01 00 00 00 00 04 |.s......|........|
|000010d0| 00 01 00 01 00 00 01 00 | 00 00 01 54 00 00 00 54 |........|...T...T|
|000010e0| 00 00 00 46 00 5c be d4 | 13 78 00 00 00 1c 00 46 |...F.\..|.x.....F|
|000010f0| 00 01 4d 50 53 52 00 00 | 00 12 4d 57 42 42 00 00 |..MPSR..|..MWBB..|
|00001100| 00 1e 03 ed ff ff 00 00 | 00 00 00 00 00 00 03 f0 |........|........|
|00001110| ff ff 00 00 00 4c 00 00 | 00 00 00 00 00 00 00 00 |.....L..|........|
|00001120| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001130| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001140| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001150| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001160| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001170| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+